import { get ,post,_put} from './http'
//获取商品列表
export const getGoodsList = (params) => {
    let url = "/api/goodsList";
    return get(url, params)
  }
  //添加商品至购物车
  export const addCart = (params) => {
    let url = "/api/cartList";
    return post(url, params)
  }
  //修改购物车列表商品数量
  export const editCartList = (params) => {
    let url = "/api/cartList/" + params.id;
    return _put(url, params)
  }

//修改商品列表商品库存
export const editGoodsList = (params) => {
    let url = "/api/goodsList/" + params.id;
    return _put(url, params)
}